<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
</head>
<body>

  <script src="./event-bus.js"></script>
  <script>
    eventBus.on('add', (data) => {
      console.log('add', data)
    })
    eventBus.on('add', (data) => {
      console.log('add2', data)
    })
    eventBus.on('delete', (data) => {
      console.log('delete', data)
    })

    // eventBus.off('add')
    eventBus.off()

    eventBus.emit('add', 123)
    eventBus.emit('delete', 'abc')


  </script>
</body>
</html>